This invention relates generally to automatic image analysis, and more specifically to distinguishing between an area of interest and a background.
Image scanners convert a visible image on a document or photograph, or an image in a transparent medium, into an electronic form suitable for copying, storing or processing by a computer. An image scanner may be a separate device, or an image scanner may be a part of a copier, part of a facsimile machine, or part of a multipurpose device. Reflective image scanners typically have a controlled source of light, and light is reflected off the surface of a document, through an optics system, and onto an array of photosensitive devices. The photosensitive devices convert received light intensity into an electronic signal. Transparency image scanners pass light through a transparent image, for example a photographic positive slide, through an optics system, and then onto an array of photosensitive devices. The invention is also applicable to digital cameras, for example, in configurations for imaging documents.
A document or other object being imaged typically does not occupy the entire field of view of the image scanner. Typically, a scanned image includes an image of interest (such as a document or photograph) and portions of a background. For example, for a reflective scanner with an automatic document feeder, the background may include portions of the automatic document feeder mechanism. For a second example, a camera looking down onto a document on a desktop may image the document of interest, and parts of the desk, and perhaps parts of other materials that are at least partially within the field of view. There is a general need to extract the image of interest from the rest of the scanned image.
Some known methods for extracting an image from a background take advantage of a known contrasting background. In U.S. Pat. No. 4,823,395, the background is black, and a white margin on a manuscript provides a contrasting edge for edge detection. Likewise, in U.S. Pat. No. 5,818,976, the optical characteristics of the background contrast with the optical characteristics of the pages to be scanned, where the contrasting background may be a shade of gray, a contrasting color, or a pattern of lines or dots. In U.S. Pat. No. 5,901,253, the scanned image is compared to a reference scan line of the background. In U.S. Pat. No. 5,880,858, a background image is obtained by scanning with no document present, and then in a scanned image including a document, pixels corresponding the background are subtracted. In U.S. Pat. No. 5,978,519, an image is cropped to include portions having variable intensity levels, and portions having uniform intensity levels are excluded from the cropped image.
Other methods are directed to removing an image of an object that overlaps the image of interest. For example, in U.S. Pat. Nos. 5,377,019 and 6,011,635, open books are imaged by a camera looking down, and thumbs and fingers of a human operator holding the book open may overlap the image of the pages. The fingers are distinguished from the book by contrasting color, and contrasting shape (curved edges).
In general, scanning devices may not be able to assume that one predetermined background is present. For example, consider a removable automatic document feeder. Sometimes the feeder is present and sometimes it is not. Alternatively, a slide adapter may be used instead of an automatic document feeder. There is a need for an image processing system that can extract an image of interest from a background, where the background may vary from one scan to the next. One approach is have a unique identifier on lids and adapters. However, if a new device is introduced after the scanner is manufactured, either hardware or software must be updated to recognize the new device. Another approach is to scan the background before each scan of an image of interest. However, scanning a background in advance of every scan adds time to the scan.
In addition, scanning devices may not be able to assume that a background is stationary from one scan to the next. For example, if a device is removed and replaced, the repeatability of the mechanical alignment may be such that the device position is slightly shifted from one time to another. Alternatively, some devices may be placed onto a scanner manually with very little precision in location.
There is a need for an image processing system that can extract an image of interest from a background, where the background may vary from one scan to the next, and where a new background may be used, and where a known background may be shifted in two dimensions.
Various backgrounds, forms, or templates are scanned, features are extracted, and the features are stored in memory. When a composite image is scanned (image of interest plus part of background), features are extracted from the composite image. Features in the composite image are correlated to stored background features to identify which background is present. If necessary, background features from memory are shifted in two dimensions to accommodate displacement of the background. Image data corresponding to the background is deleted from the composite image. The invention is also applicable to extraction of information that has been added to a blank form.